package com.younion.vo;

import cpcns.component.common.base.BaseVO;
import cpcns.persister.converter.IDomainObject;
import cpcns.persister.service.CompositeID;

import java.util.Date;

/**
 * 
 * 描述: 商家 实体类
 * 
 * @property label="商家" lower="customer" upper="CUSTOMER" instance="customer"
 *           table="t_Customer"
 * 
 * Copyright (c) 2009 Excellence Network Co.,LTD All right reserved.
 * 
 */
public class CustomerVO extends BaseVO implements IDomainObject, Cloneable {

	/**  */
	private static final long serialVersionUID = -1L;

	/**
	 * 序列
	 * 
	 * @label 序列
	 * @code id
	 * @type NUMERIC
	 * @javaType Integer
	 * @pk instance="Id"
	 * @required true
	 * @index 1
	 * @oddeven 0
	 */
	private Integer id;

	/**
	 * 商家编码
	 * 
	 * @label 商家编码
	 * @code code
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 20
	 * @index 2
	 * @oddeven 1
	 * @faint
	 */
	private String code;

	/**
	 * 商家名称
	 * 
	 * @label 商家名称
	 * @code name
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 20
	 * @index 3
	 * @oddeven 2
	 * @isAfterTwo 2
	 * @faint
	 */
	private String name;

	/**
	 * 商家介绍
	 * 
	 * @label 商家介绍
	 * @code introduce
	 * @type LONGTEXT
	 * @javaType String
	 * @show
	 * @index 4
	 * @oddeven 1
	 * @isAfterTwo 1
	 * @typeHandle org.springframework.orm.ibatis.support.ClobStringTypeHandler
	 * @faint
	 */
	private String introduce;

	/**
	 * 合同编码
	 * 
	 * @label 合同编码
	 * @code contract_code
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 30
	 * @index 5
	 * @oddeven 2
	 * @isAfterTwo 2
	 * @faint
	 */
	private String contractCode;

	/**
	 * 加盟开始时间
	 * 
	 * @label 加盟开始时间
	 * @code join_begtime
	 * @type TIMESTAMP
	 * @javaType java.util.Date
	 * @show
	 * @index 6
	 * @oddeven 1
	 * @isAfterTwo 1
	 */
	private Date joinBegtime;

	/**
	 * 加盟结束时间
	 * 
	 * @label 加盟结束时间
	 * @code join_endtime
	 * @type TIMESTAMP
	 * @javaType java.util.Date
	 * @show
	 * @index 7
	 * @oddeven 2
	 * @isAfterTwo 2
	 */
	private Date joinEndtime;

	/**
	 * 联系人
	 * 
	 * @label 联系人
	 * @code linkman
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 5
	 * @index 8
	 * @oddeven 1
	 * @isAfterTwo 1
	 * @faint
	 */
	private String linkman;

	/**
	 * 固定电话
	 * 
	 * @label 固定电话
	 * @code telphone
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 6
	 * @index 9
	 * @oddeven 2
	 * @isAfterTwo 2
	 * @faint
	 */
	private String telphone;

	/**
	 * 移动电话
	 * 
	 * @label 移动电话
	 * @code mobile
	 * @type VARCHAR
	 * @javaType String
	 * @show
	 * @length 6
	 * @index 10
	 * @oddeven 1
	 * @isAfterTwo 1
	 * @faint
	 */
	private String mobile;

	/**
	 * 总发卡量
	 * 
	 * @label 总发卡量
	 * @code card_total
	 * @type NUMERIC
	 * @javaType Integer
	 * @show
	 * @index 11
	 * @oddeven 2
	 * @isAfterTwo 2
	 */
	private Integer cardTotal;

	/**
	 * 是否有优惠券
	 * 
	 * @label 是否有优惠券
	 * @code have_favourable
	 * @type NUMERIC
	 * @javaType Double
	 * @show
	 * @index 12
	 * @oddeven 1
	 * @isAfterTwo 1
	 */
	private Integer haveFavourable;

	/**
	 * 是否核心商家
	 */
	private Integer isCoreCustomer;
	
	/**
	 * 是否支持联盟优惠
	 * 
	 * @label 是否支持联盟优惠
	 * @code have_alliance_favourable
	 * @type NUMERIC
	 * @javaType Double
	 * @show
	 * @index 13
	 * @oddeven 2
	 * @isAfterTwo 2
	 */
	private Integer haveAllianceFavourable;

	/** 所属省份* */
	private RegioninfoVO province;

	/** 所属市级* */
	private RegioninfoVO city;

	/** 所属城区* */
	private RegioninfoVO district;

	/**
	 * 商家分类
	 * 
	 * @label 商家分类
	 * @code customer_kind_id
	 * @type NUMERIC
	 * @javaType Integer
	 * @show
	 * @index 18
	 * @oddeven 1
	 * @isAfterTwo 1
	 */
	private Integer customerKindId;

	/**
	 * 商家账户
	 * 
	 * @label 商家账户
	 * @code customer_account_id
	 * @type NUMERIC
	 * @javaType Integer
	 * @show
	 * @isLast
	 * @index 19
	 * @oddeven 2
	 * @isAfterTwo 2
	 */
	private Integer customerAccountId;

	/**
	 * 合作状态:0正常合作 1解除合作
	 */
	private Integer cooperationStaus;
	
	private Double money;
	
	private Integer top;
	
	private String picName;
	
	private String memberBenefits;
	
	private String balanceUrl;
	
	private String countUrl;
	
	private Double gtmoney;
	private Double ltmoney;
	private Integer gtcardTotal;
	private Integer ltcardTotal;
	
	//解决查询时PropertyUtils.describe无法深层次多个处理属性值问题
	private String provinceRegionId;
	private String cityRegionId;
	private String districtRegionId;
	
	
	public CustomerVO() {
	}

	/**
	 * 
	 */
	public CustomerVO(Integer id) {
		this.id = id;
	}

	/**
	 * @return the id
	 */
	public Integer getId() {
		return id;
	}

	/**
	 * @param id
	 *            the id to set
	 */
	public void setId(Integer id) {
		this.id = id;
	}

	/**
	 * @return the code
	 */
	public String getCode() {
		return code;
	}

	/**
	 * @param code
	 *            the code to set
	 */
	public void setCode(String code) {
		this.code = code;
	}

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the introduce
	 */
	public String getIntroduce() {
		return introduce;
	}

	/**
	 * @param introduce
	 *            the introduce to set
	 */
	public void setIntroduce(String introduce) {
		this.introduce = introduce;
	}

	/**
	 * @return the contractCode
	 */
	public String getContractCode() {
		return contractCode;
	}

	/**
	 * @param contractCode
	 *            the contractCode to set
	 */
	public void setContractCode(String contractCode) {
		this.contractCode = contractCode;
	}

	/**
	 * @return the joinBegtime
	 */
	public Date getJoinBegtime() {
		return joinBegtime;
	}

	/**
	 * @param joinBegtime
	 *            the joinBegtime to set
	 */
	public void setJoinBegtime(Date joinBegtime) {
		this.joinBegtime = joinBegtime;
	}

	/**
	 * @return the joinEndtime
	 */
	public Date getJoinEndtime() {
		return joinEndtime;
	}

	/**
	 * @param joinEndtime
	 *            the joinEndtime to set
	 */
	public void setJoinEndtime(Date joinEndtime) {
		this.joinEndtime = joinEndtime;
	}

	/**
	 * @return the linkman
	 */
	public String getLinkman() {
		return linkman;
	}

	/**
	 * @param linkman
	 *            the linkman to set
	 */
	public void setLinkman(String linkman) {
		this.linkman = linkman;
	}

	/**
	 * @return the telphone
	 */
	public String getTelphone() {
		return telphone;
	}

	/**
	 * @param telphone
	 *            the telphone to set
	 */
	public void setTelphone(String telphone) {
		this.telphone = telphone;
	}

	/**
	 * @return the mobile
	 */
	public String getMobile() {
		return mobile;
	}

	/**
	 * @param mobile
	 *            the mobile to set
	 */
	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	/**
	 * @return the cardTotal
	 */
	public Integer getCardTotal() {
		return cardTotal;
	}

	/**
	 * @param cardTotal
	 *            the cardTotal to set
	 */
	public void setCardTotal(Integer cardTotal) {
		this.cardTotal = cardTotal;
	}

	public Integer getHaveFavourable() {
		return haveFavourable;
	}

	public void setHaveFavourable(Integer haveFavourable) {
		this.haveFavourable = haveFavourable;
	}

	public Integer getHaveAllianceFavourable() {
		return haveAllianceFavourable;
	}

	public void setHaveAllianceFavourable(Integer haveAllianceFavourable) {
		this.haveAllianceFavourable = haveAllianceFavourable;
	}


	/**
	 * @return the customerKindId
	 */
	public Integer getCustomerKindId() {
		return customerKindId;
	}

	/**
	 * @param customerKindId
	 *            the customerKindId to set
	 */
	public void setCustomerKindId(Integer customerKindId) {
		this.customerKindId = customerKindId;
	}

	/**
	 * @return the customerAccountId
	 */
	public Integer getCustomerAccountId() {
		return customerAccountId;
	}

	public Integer getCooperationStaus() {
		return cooperationStaus;
	}

	public void setCooperationStaus(Integer cooperationStaus) {
		this.cooperationStaus = cooperationStaus;
	}

	/**
	 * @param customerAccountId
	 *            the customerAccountId to set
	 */
	public void setCustomerAccountId(Integer customerAccountId) {
		this.customerAccountId = customerAccountId;
	}

	public Integer getIsCoreCustomer() {
		return isCoreCustomer;
	}

	public void setIsCoreCustomer(Integer isCoreCustomer) {
		this.isCoreCustomer = isCoreCustomer;
	}

	
	public Double getMoney() {
		return money;
	}

	public void setMoney(Double money) {
		this.money = money;
	}

	public CompositeID getCompositeID() {
		CompositeID _id = super.getCompositeID();
		_id.clear();
		if (id != null) {
			_id.addKey("id", id);
		}
		return _id;
	}

	public String getPicName() {
		return picName;
	}

	public void setPicName(String picName) {
		this.picName = picName;
	}

	public Integer getTop() {
		return top;
	}

	public void setTop(Integer top) {
		this.top = top;
	}

	public String getMemberBenefits() {
		return memberBenefits;
	}

	public void setMemberBenefits(String memberBenefits) {
		this.memberBenefits = memberBenefits;
	}

	public RegioninfoVO getProvince() {
		return province;
	}

	public void setProvince(RegioninfoVO province) {
		this.province = province;
	}

	public RegioninfoVO getCity() {
		return city;
	}

	public void setCity(RegioninfoVO city) {
		this.city = city;
	}

	public RegioninfoVO getDistrict() {
		return district;
	}

	public void setDistrict(RegioninfoVO district) {
		this.district = district;
	}

	public String getBalanceUrl() {
		return balanceUrl;
	}

	public void setBalanceUrl(String balanceUrl) {
		this.balanceUrl = balanceUrl;
	}

	public String getCountUrl() {
		return countUrl;
	}

	public void setCountUrl(String countUrl) {
		this.countUrl = countUrl;
	}

	public Double getGtmoney() {
		return gtmoney;
	}

	public void setGtmoney(Double gtmoney) {
		this.gtmoney = gtmoney;
	}

	public Double getLtmoney() {
		return ltmoney;
	}

	public void setLtmoney(Double ltmoney) {
		this.ltmoney = ltmoney;
	}

	public Integer getGtcardTotal() {
		return gtcardTotal;
	}

	public void setGtcardTotal(Integer gtcardTotal) {
		this.gtcardTotal = gtcardTotal;
	}

	public Integer getLtcardTotal() {
		return ltcardTotal;
	}

	public void setLtcardTotal(Integer ltcardTotal) {
		this.ltcardTotal = ltcardTotal;
	}

	public String getCityRegionId() {
		return cityRegionId;
	}

	public void setCityRegionId(String cityRegionId) {
		this.cityRegionId = cityRegionId;
	}

	public String getDistrictRegionId() {
		return districtRegionId;
	}

	public void setDistrictRegionId(String districtRegionId) {
		this.districtRegionId = districtRegionId;
	}

	public String getProvinceRegionId() {
		return provinceRegionId;
	}

	public void setProvinceRegionId(String provinceRegionId) {
		this.provinceRegionId = provinceRegionId;
	}
	
}
